/*=====================================================================================================================
                    Copyright(c) 2010 Geometric PLM Software Corp. All rights reserved.
                             Unpublished - All rights reserved
=======================================================================================================================
File description:
    Filename: tc_encrypt.h
    Module  : Common module.

        This file implement the encrypt/decipher of string.

=======================================================================================================================
Date               Name              Description of Change
19-Jan-2010        Penn,Xie          Initialize creation
$HISTORY$
=====================================================================================================================*/
#ifndef TC_ENCRYPT_H
#define TC_ENCRYPT_H

#ifdef __cplusplus
    extern "C"
    {
#endif

    /**
    * Simply encrypt the string.
    * @param str - <I> the source string.
    * @param key - <I> the key,ONLY in [1, 93].
    * 
    *       For the result string is displayable in ASCII, 
    *       here limit the key value in the area, [1, 93].
    *       All character can be displayable is in the ASCII area [33, 126].
    * @return - N/A
    */
    extern void GENC_encrypt( char *str, int key );

    /**
    * Simply decrypt the string.
    * @param str - <I> the source string.
    * @param key - <I> the key,ONLY in [1, 93].
    * 
    *       For the result string is displayable in ASCII, 
    *       here limit the key value in the area, [1, 93].
    *       All character can be displayable is in the ASCII area [33, 126].
    * @return - N/A.
    */
    extern void GENC_decrypt( char *str, int key );

#ifdef __cplusplus
    }
#endif

#endif //STRING_UTILS_H
